package g11.model;

import java.io.Serializable;

public class PatientAssignment implements Serializable {

	private static final long serialVersionUID = -5479666006581920674L;

	private Integer doctorId;
	private Integer patientId;
	private byte permission;

	public Integer getDoctorId() {
		return doctorId;
	}

	public void setDoctorId(Integer doctorId) {
		this.doctorId = doctorId;
	}

	public Integer getPatientId() {
		return patientId;
	}

	public void setPatientId(Integer patientId) {
		this.patientId = patientId;
	}

	public byte getPermission() {
		return permission;
	}

	public void setPermission(byte permission) {
		this.permission = permission;
	}

	public static long getSerialversionuid() {
		return serialVersionUID;
	}

	@Override
	public boolean equals(Object obj) {
		/*
		 * add by Fern
		 */
		PatientAssignment other = (PatientAssignment) obj;
		if ((this.patientId == other.patientId)
				&& (this.doctorId == other.doctorId)) {
			return true;
		} else

			return false;
	}

	@Override
	public String toString() {
		return "PatientAssignment [doctorId=" + doctorId + ", patientId="
				+ patientId + ", permission=" + permission + "]";
	}

}
